#!/sbin/openrc-run

name="Bareos Director daemon"
pidfile=/run/bareos/bareos-dir.9101.pid
command=/usr/sbin/bareos-dir
command_args="-u bareos -g bareos"

depend() {
	need net
	after firewall
	use dns bareos-fd bareos-sd postgresql mariadb
}

start_pre() {
	checkpath -dm750 -o bareos "${pidfile%/*}"
}
